MAT-7471: Disable auto-encoding on FhirTerminologyServiceWebClient #97
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Terminology Service PR
Jira Ticket: MAT-7471
(Optional) Related Tickets:
Summary
Manually control when uri data is html encoded by disabling auto-encoding on
FhirTerminologyServiceWebClient
.Our config of the
FhirTerminologyServiceWebClient
auto-encodes String uri values by way of setting theWebClient.Builder baseUrl()
. Effectively, doing so serves as a shortcut to use the defaultUriBuilderFactory
, which is configured to encode uri Strings by default.When a URI object is passed to the WebClient request chain, the
UriBuilderFactory
is not used. Instead, the WebClient uses the supplied URI as is. Which also means it does not use thebaseUrl
set on the WebClient since thebaseUrl
is passed down to the defaultUriBuilderFactory
instance that gets bypassed when making a request with a URI object.See: https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/web/reactive/function/client/WebClient.Builder.html#baseUrl(java.lang.String)
See: https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/web/util/DefaultUriBuilderFactory.html#setEncodingMode(org.springframework.web.util.DefaultUriBuilderFactory.EncodingMode)
All Submissions
DevSecOps
If there is a question if this PR has a security or infrastructure impact, please contact the Security or DevOps engineer assigned to this project to discuss it further.
Reviewers
By Approving this PR you are attesting to the following: